/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
 *																					 *
 * Copyright (c) 2003-2006 by AG-Software											 *
 * All Rights Reserved.																 *
 *																					 *
 * You should have received a copy of the AG-Software Shared Source License			 *
 * along with this library; if not, email gnauck@ag-software.de to request a copy.   *
 *																					 *
 * For general enquiries, email gnauck@ag-software.de or visit our website at:		 *
 * http://www.ag-software.de														 *
 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */

using System;

using agsXMPP.Xml.Dom;

namespace agsXMPP.protocol.iq.disco
{
	/// <summary>
	/// Disco feature
	/// </summary>
	/// <remarks>
	/// see: http://www.jabber.org/registrar/disco-features.html
	/// </remarks>
	public class DiscoFeature : Element
	{
		/*
		<iq type='result'
			from='plays.shakespeare.lit'
			to='romeo@montague.net/orchard'
			id='info1'>
		<query xmlns='http://jabber.org/protocol/disco#info'>
			<identity
				category='conference'
				type='text'
				name='Play-Specific Chatrooms'/>
			<identity
				category='directory'
				type='chatroom'
				name='Play-Specific Chatrooms'/>
			<feature var='http://jabber.org/protocol/disco#info'/>
			<feature var='http://jabber.org/protocol/disco#items'/>
			<feature var='http://jabber.org/protocol/muc'/>
			<feature var='jabber:iq:register'/>
			<feature var='jabber:iq:search'/>
			<feature var='jabber:iq:time'/>
			<feature var='jabber:iq:version'/>
		</query>
		</iq>
		*/
		public DiscoFeature()
		{
			this.TagName	= "feature";
			this.Namespace	= Uri.DISCO_INFO;
		}

		public DiscoFeature(string var) : this()
		{
			Var = var;
		}

		/// <summary>
		/// feature name or namespace
		/// </summary>
		public string Var
		{
			get { return GetAttribute("var"); }
			set { SetAttribute("var", value); }
		}
	}
}
